<?php

use yii\helpers\Html;
use yii\widgets\ActiveForm;
use common\models\City;
use yii\web\View;
use yii\helpers\ArrayHelper;
use backend\models\OperatorRelation;
//$province = City::findBySql("select * from grp_city where id like '%0000'")->all();
/* @var $this yii\web\View */
/* @var $model backend\models\BuildCity */
/* @var $form yii\widgets\ActiveForm */
$this->registerJs("
 
  ",View::POS_END);
?>
  
</script>
<div class="build-city-form">

   <?php $form = ActiveForm::begin(['options' => ['enctype' => 'multipart/form-data']]); ?>
    <?= $form->field($model, 'name')->textInput(['maxlength' => true]) ?>
    <?= $form->field($model, 'city')->textInput() ?>
    <?= $form->field($model, 'village')->textInput() ?>
    <?= $form->field($model, 'house_type')->textInput() ?>
    <?= $form->field($model, 'area')->textInput() ?>
	<?= $form->field($model, 'cost')->textInput() ?>
    <?= $form->field($model, 'brief')->textInput() ?>
        <?= $form->field($model, 'app_return')->radioList(\backend\models\Vr::$app_return)  ?>
    <?= $form->field($model, 'vr_flag')->radioList(\backend\models\Vr::$vr_flag) ?>

    <?= $form->field($model, 'image_upload')->fileInput(['class' => 'btn', 'style' => 'background-color:#ccc']) ?>
    <?= $form->field($model, 'desc')->widget('backend\widgets\ueditor\UEditor',[
        'options'=>[
            'initialFrameWidth' => 850,
        ]
    ]) ?>
    <div class="form-group">
        <?= Html::submitButton($model->isNewRecord ? Yii::t('app', 'Create') :  Yii::t('app', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']) ?>
    </div>

    <?php ActiveForm::end(); ?>

</div>
